From 8d934c571fb954232c4cbe6f1dab554a35ad5e7d Mon Sep 17 00:00:00 2001 From: Justin Burkett Date: Sun, 13 Feb 2022 22:33:02 -0500 Subject: [PATCH] Don't allow transient maps when prefix length is zero. Fixes #335 --- which-key.el | 3 +++ 1 file changed, 3 insertions(+) diff --git a/which-key.el b/which-key.el index c13f4af25aa..d2743198fa1 100644 --- a/which-key.el +++ b/which-key.el @@ -2655,6 +2655,9 @@ Finally, show the buffer." (not which-key--secondary-timer-active)) (which-key--start-timer which-key-idle-secondary-delay t)))) ((and which-key-show-transient-maps + ;; Assuming that if this is not true we're in + ;; `which-key-show-top-level', which would then be overwritten. + (> (length prefix-keys) 0) (keymapp overriding-terminal-local-map) ;; basic test for it being a hydra (not (eq (lookup-key overriding-terminal-local-map "\C-u") -- 2.30.2